import request from '@/utils/request'

// 查询班组列表
export function listTeam(query) {
  return request({
    url: '/group/team/list',
    method: 'get',
    params: query
  })
}

// 查询班组列表(分页)
export function pageTeam(query) {
  return request({
    url: '/group/team/page',
    method: 'get',
    params: query
  })
}

// 查询班组详细
export function getTeam(teamId) {
  return request({
    url: '/group/team/get/' + teamId,
    method: 'get'
  })
}

// 新增班组
export function addTeam(data) {
  return request({
    url: '/group/team/add',
    method: 'post',
    data: data
  })
}

// 修改班组
export function updateTeam(data) {
  return request({
    url: '/group/team/edit',
    method: 'post',
    data: data
  })
}

// 删除班组
export function delTeam(teamId) {
  return request({
    url: '/group/team/remove/' + teamId,
    method: 'post'
  })
}
